import request from '@/utils/request'

// 查询facility列表
export function listFacility(query) {
  return request({
    url: '/camp/facility/list',
    method: 'get',
    params: query
  })
}
// /wechat/facility/list

// 查询facility详细
export function getFacility(facilityId) {
  return request({
    url: '/camp/facility/' + facilityId,
    method: 'get'
  })
}

// 新增facility
export function addFacility(data) {
  return request({
    url: '/camp/facility',
    method: 'post',
    data: data
  })
}

// 修改facility
export function updateFacility(data) {
  return request({
    url: '/camp/facility',
    method: 'put',
    data: data
  })
}

// 删除facility
export function delFacility(facilityId) {
  return request({
    url: '/camp/facility/' + facilityId,
    method: 'delete'
  })
}

//查询设施类型
export function queryInfo(ftId) {
  return request({
    url: '/camp/facility/queryInfo/' + ftId,
    method: 'get'
  })
}
